﻿using System;
using System.Collections.Generic;
using System.Text;
using Store.Dal;
using Store.Model.Models;


namespace Store.Bll
{
    public class UsersBll
    {
        private readonly UsersDal bll;
        public UsersBll(UsersDal _bll)
        {
            bll = _bll;
        }

        public List<User> GetUsers(string id, string name, int pageIndex, int pageSize, out int total)//显示
        {
            var str = bll.GetUsers(id,name,pageIndex, pageSize,out total);
            return str;
        }
        public int Delete(int id)
        {
            return bll.Delete(id);
        }
        public int Update(User user)
        {
            return bll.Update(user);
        }
        public User fantian(int id)
        {
            return bll.fantian(id);
        }
        public int Add(User user)
        {
            return bll.Add(user);
        }
        public List<User> GetUsers2(string userName, string userAccount, string userPrice, string userCount, string userAvg, int pageIndex, int pageSize, out int total)//条件查询
        {
            return bll.GetUsers2(userName,userAccount,userPrice,userCount,userAvg,pageIndex,pageSize,out total);
        }
    }
}
